﻿using System;
using System.Collections.Generic;
using System.Text;
using EnCor.Security;
using System.Web.Security;

namespace EnCor.Aspnet.Security
{
    public class AspnetCredential : Credential
    {
        private FormsAuthenticationTicket _Ticket;
        public AspnetCredential(FormsAuthenticationTicket ticket)
        {
            _Ticket = ticket;
        }

        public override string Type
        {
            get { return CredentialTypes.AspnetFormsCredential; }
        }

        public override string Name
        {
            get { return _Ticket.Name; }
        }

        public FormsAuthenticationTicket Ticket
        {
            get
            {
                return _Ticket;
            }
        }
    }
}
